﻿@using SuperDumpService.Helpers
@inject IAuthorizationHelper AuthorizationHelper

<nav class="navbar navbar-default navbar-fixed-top navbar-expand-lg" id="mainNavbar">
	<div class="container row">
		<div class="navbar-header">
			<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
				<span class="sr-only">Toggle navigation</span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
			</button>
			<a asp-area="" asp-controller="Home" asp-action="Index" class="navbar-brand">SuperDump</a>
		</div>
		<div class="navbar-collapse collapse">
			<ul class="nav navbar-nav">
				<li><a asp-area="" asp-controller="Home" asp-action="Dumps">Dumps</a></li>
				@if (AuthorizationHelper.CheckPolicy(User, LdapCookieAuthenticationExtension.AdminPolicy)) {
					<li><a href="/hangfire">Hangfire</a></li>
					<li><a asp-area="" asp-controller="Admin" asp-action="Overview">Admin</a></li>
				}
				<li><a href="/swagger">API Doc</a></li>
				<li><a asp-area="" asp-controller="Home" asp-action="Elastic">Elastic</a></li>
				<li><a asp-area="" asp-controller="Home" asp-action="About">About</a></li>
			</ul>
			<partial name="_LoginPartial" />
		</div>
	</div>
</nav>